package com.biz.primus.ms.oms.feign;

import com.biz.primus.model.stock.vo.IncrDepotStockReqVo;
import com.biz.primus.model.stock.vo.MeetHomeStockReqVo;
import com.biz.primus.model.stock.vo.MeetStockRespVo;
import com.biz.primus.model.stock.vo.ProvinceStockReqVo;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @author  LGJ
 * @date  2017/11/8
 */
@FeignClient(qualifier = "stockFeignClient", name = "service-stock")
public interface StockFeignClient {


    /**
     * 获取省内满足库存的门店
     * @param reqVo
     * @return
     */
    @GetMapping("soa/stockService/getMeetByProvince")
    MeetStockRespVo getMeetByProvince(@RequestBody ProvinceStockReqVo reqVo);

    /**
     * 获取太原市中心满足库存且数量最多的门店
     * @param reqVo
     * @return
     */
    @GetMapping("soa/stockService/getMeetByHome")
    MeetStockRespVo getMeetByHome(@RequestBody MeetHomeStockReqVo reqVo);

    /**
     * 更新门店库存
     * @param reqVo
     */
    @PostMapping("soa/stockService/updateStockOnly")
    void updateStockOnly(@RequestBody IncrDepotStockReqVo reqVo);
}
